function fun(){
    var bigTable = document.querySelector(".bigTable");//主桌大div
    var circle = bigTable.querySelectorAll(".circle");
    var cir_box = document.querySelector(".cir_box");//次卓大div
    var ci_circle = cir_box.querySelectorAll(".circle");
    var tables = document.querySelectorAll(".hastable");//次卓大div儿子
    var addtable = document.querySelector(".addtable");//添桌
    var f_text = document.querySelector(".f_text");//
    var f_text2 = document.querySelector(".f_text2");
    console.log(cir_box.children);
    //次桌选座位 


    //主桌选座位
    var isClick =true;
    bigTable.addEventListener("click",function(){
    bigTable.style.transform = "scale(2)";
    bigTable.style.top = "45vw";
    addtable.style.display = "none";
    f_text.style.display = "none";
    f_text2.style.display = "block";
    for(let i = 0;i<tables.length;i++){
        tables[i].style.display = "none";
    //          console.log(tables[i]);
    }
    })

    bigTable.addEventListener("click",function(){
            bigTable.style.transform = "scale(2)";
            bigTable.style.top = "45vw";
            addtable.style.display = "none";
            f_text.style.display = "none";
            f_text2.style.display = "block";
            for(let i = 0;i<tables.length;i++){
            tables[i].style.display = "none";
    //          console.log(tables[i]);
            }
    })
    for(let i = 0;i<tables.length;i++){
    tables[i].addEventListener("click",function(){
            for(let j = 0;j<tables.length;j++){
                    tables[j].style.display = "none";
            }
            bigTable.style.display = "none";
            tables[i].style.display = "block";
            // tables[i].style.margin = "0vw auto"
            tables[i].style.left = "40%"
            tables[i].style.top = "60vw";
            tables[i].style.transform = "scale(2.7)";
            addtable.style.display = "none";
            f_text.style.display = "none";
            f_text2.style.display = "block";
    })     
    }
    var back = document.querySelector(".back");
    back.addEventListener("click",function(){
    for(let i = 0;i<tables.length;i++){
            tables[i].style.display = "block";
            tables[i].style.transform = "scale(1)";
            // tables[i].style.margin = "none"
            tables[i].style.left = "0%";
            tables[i].style.transform = "translateX(0)"
            tables[i].style.top = "0vw";
    }
    bigTable.style.display = "block";
    bigTable.style.top = "0vw";
    bigTable.style.transform = "scale(1)";
    f_text.style.display = "block";
    f_text2.style.display = "none";
    addtable.style.display = "block";

    })       
}
//无用的文件,可删除


